Ext.namespace("SysMgr.Main");

SysMgr.Main.tabIndex = {
	"group" : 0
};
SysMgr.Main.tabs = [];

SysMgr.initUI = function() {
	var opentab = Utils.getParameter('opentab');
	if (!opentab) opentab = "group";
	
	// init tabs
	SysMgr.Main.tabs.push(new SysMgr.GroupList());
	
	SysMgr.instance = new Ext.TabPanel({
		region: 'center',
		activeTab: SysMgr.Main.tabIndex[opentab],
		items: SysMgr.Main.tabs
	});
	
	var mainview = new Ext.Viewport({
        layout:'border',
        items:[SysMgr.instance]
    });
};

Ext.onReady(function(){
	Ext.QuickTips.init();
    Ext.BLANK_IMAGE_URL = '../resources/images/default/s.gif';
	SysMgr.initUI();
});